package hall
{
	import feathers.controls.Button;
	import feathers.controls.Callout;
	import feathers.controls.Label;
	import feathers.themes.MetalWorksMobileTheme;
	
	import starling.display.Sprite;
	import starling.events.Event;

	public class DUIHall extends Sprite
	{
		private var theme:MetalWorksMobileTheme;
		private var button:Button;
		
		public function DUIHall()
		{
			this.addEventListener( Event.ADDED_TO_STAGE, addedToStageHandler );
		}
		
		private function addedToStageHandler(e:Event):void
		{
			this.theme = new MetalWorksMobileTheme(this.stage);
			
			this.button = new Button();
			this.button.label = "Click Me";
			this.addChild(button);
			
			this.button.addEventListener(Event.TRIGGERED, bt);
			
			this.button.validate();
			this.button.x = (this.stage.stageWidth - this.button.width) / 2;
			this.button.y = (this.stage.stageHeight - this.button.height) / 2;
		}
		
		private function bt(e:Event):void
		{
			const label:Label = new Label();
			label.text = "Hi, I'm Feathers!\nHave a nice day.";
			Callout.show(label, this.button);
		}
		
		/**
		 * 房间列表信息
		 * @param	list
		 */
		public function refreshRoomList():void
		{
//			m_roomPane.refreshRoomListInfo();
		}
	}
}